package com.zb.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.zb.entity.AccounLoginInfo;
import com.zb.entity.ZjWorkCancel;

import java.util.List;

/**
 * <p>
 * 工单取消表 服务类
 * </p>
 *
 * @author WEN
 * @since 2023-11-29
 */
public interface ZjWorkCancelService extends IService<ZjWorkCancel> {

    /**
     * 保存服务商取消工单申请
     * @param loginInfo 账号信息
     * @param workId 工单ID
     * @param remark 备注
     */
    void saveNetworkApplyCancelOrder(AccounLoginInfo loginInfo, Long workId, String remark);

    /**
     * 根据[工单ID]&[服务商ID]与[服务商人员ID]获取取消工单信息
     * @param workId 工单ID
     * @param networkId 服务商ID
     * @param networkEmpId 服务商人员ID
     * @return
     */
    ZjWorkCancel getCancelOrderByWorkIdAndNetworkIdWidthNetworkEmpId(Long workId, Long networkId, Long networkEmpId);

    /**
     * 根据工单ID获取待审核的取消工单数据
     * @param workId 工单ID
     * @return
     */
    ZjWorkCancel getWaitCheckCancelOrder(Long workId);

    /**
     * 根据工单ID获取待审核的取消工单
     * @param networkId 服务商ID
     * @param workIds 工单ID
     * @return
     */
    List<ZjWorkCancel> getWaitCheckCancelOrderByNetworkIdAndWorkIds(Long networkId, List<Long> workIds);
}
